package com.yesep.common.exception;
import com.yesep.common.enumm.RetEnum;

/**
 * @author: quliang
 * @date: 2019-7-12 09:30:44
 * @description: 异常类
 */
public class ServiceException extends RuntimeException {

    private RetEnum retEnum;

    public ServiceException(RetEnum retEnum) {
        this.retEnum = retEnum;
    }

    public static ServiceException build(RetEnum retEnum) {
        ServiceException serviceException = new ServiceException(retEnum);
        return serviceException;
    }

    public RetEnum getRetEnum() {
        return retEnum;
    }
}
